package FitNess;



import java.io.FileNotFoundException;
import java.io.FileWriter;
import java.io.IOException;
import java.util.Date;

public class ErreurLob {
	
	public static void RedigerErreur(String texte) throws IOException{
		FileWriter fw =null;
		try {
			Date dd=new Date();
			@SuppressWarnings("deprecation")
			String date=""+dd.toLocaleString();
			date=date.replaceAll(":", "-");
			fw =new FileWriter("ErreurLob/"+date+".txt");
			fw.write(texte);
		} catch (FileNotFoundException e) {
			e.printStackTrace();
		} catch (IOException e) {
		}finally{
			if(fw!=null)
				try {
					fw.close();
				} catch (IOException e) {
					e.printStackTrace();
				}
		}
	}
}